package com.github.zxhtom.excel.model;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.github.zxhtom.excel.constant.HeadConstant;
import lombok.Builder;
import lombok.Data;
import lombok.experimental.Accessors;

import java.util.Date;

/**
 * @package com.github.zxhtom.excel.model
 * @Class Student
 * @Description 学生实体
 * @Author zhangxinhua
 * @Date 19-10-31 下午3:43
 */
@Data
@Builder
@Accessors(chain = true)
public class Student {

    /**
     * 学生索引id
     */
    @ExcelProperty(value = {HeadConstant.FIRSTNAME,HeadConstant.SECONDNAME,"学号"})
    @Excel(name = "学号")
    private String id;
    /**
     * 姓名
     */
    @ExcelProperty(value = {HeadConstant.FIRSTNAME,HeadConstant.SECONDNAME,"姓名"})
    @Excel(name = "姓名")
    private String userName;

    /**
     * 用户昵称
     */
    @ExcelProperty(value = {HeadConstant.FIRSTNAME,HeadConstant.SECONDNAME,"昵称"})
    @Excel(name = "昵称")
    @ExcelIgnore
    @cn.afterturn.easypoi.excel.annotation.ExcelIgnore()
    private String userNick;

    /**
     * 年龄
     */
    @ExcelProperty(value = {HeadConstant.FIRSTNAME,HeadConstant.SECONDNAME,"年龄"})
    @Excel(name = "年龄")
    private Integer age;
    /**
     * 性别 true : 男  ； false : 女
     */
    @ExcelProperty(value = {HeadConstant.FIRSTNAME,HeadConstant.SECONDNAME,"性别"})
    @Excel(name = "性别")
    private boolean sex;
    /**
     * 生日
     */
    @ExcelProperty(value = {HeadConstant.FIRSTNAME,HeadConstant.SECONDNAME,"生日"})
    @Excel(name = "生日")
    private Date birth;
    /**
     * 身高
     */
    @ExcelProperty(value = {HeadConstant.FIRSTNAME,HeadConstant.SECONDNAME,"身高"})
    @Excel(name = "身高")
    private Double height;

}
